import { EventTarget } from "cc";
import Singleton from "./Singleton";

class Dispatch extends Singleton {

    public get entity():EventTarget { return this._eventTarget; }

    protected onCreate(): void {
        this._eventTarget = new EventTarget();
    }

//private
    private _eventTarget:EventTarget = null!;
}

const Dispatcher = Dispatch.getInstance() as Dispatch;
export default Dispatcher;